﻿using System;
using System.Threading;
using ShuttleBus;

namespace Tests.Integration
{
    public class MessageHandler : IHandle<MyMessage>, IHandle<OtherMessage>
    {
        public void Handle(MyMessage message)
        {
            Console.WriteLine("MessageHandler Handled MyMessage: {0} on Thread: {1}", message.Id, Thread.CurrentThread.ManagedThreadId);
        }

        public void Handle(OtherMessage message)
        {
            Console.WriteLine("MessageHandler Handled OtherMessage: {0} on Thread: {1}", message.Id, Thread.CurrentThread.ManagedThreadId);
        }
    }
}